﻿@model WebGioiThieu.Models.MenuItem

@{
    ViewBag.Title = "Create";
}

<h2>Create</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>MenuItem</legend>

        <div class="editor-label">
            Nhập tên menu(*)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Ten)
            @Html.ValidationMessageFor(model => model.Ten)
        </div>

        <div class="editor-label">
            Bí danh(vd: ten-cua-menu)(*)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.BiDanh)
            @Html.ValidationMessageFor(model => model.BiDanh)
        </div>

        <div class="editor-label">
           Thuộc menu nào?(*)
        </div>
        <div class="editor-field">
            @Html.DropDownList("MenuTypeID", String.Empty)
            @Html.ValidationMessageFor(model => model.MenuTypeID)
        </div>

        <div class="editor-label">
            Chọn menu cha
        </div>
        <div class="editor-field">
            @Html.DropDownList("Parent", "")
            @Html.ValidationMessageFor(model => model.Parent)
        </div>

        <div class="editor-label">
            @Html.LabelFor(t=>t.ThuTu)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ThuTu)
            @Html.ValidationMessageFor(model => model.ThuTu)
        </div>

        <div class="editor-label">
            Cho phép hiển thị hay không?
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.TrangThai)
            @Html.ValidationMessageFor(model => model.TrangThai)
        </div>

        <div class="editor-label">
            Liên kết cứng
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.LienKet)
            @Html.ValidationMessageFor(model => model.LienKet)
        </div>

        <div class="editor-label">
           Mô tả ngắn
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.MoTa)
            @Html.ValidationMessageFor(model => model.MoTa)
        </div>

        <div class="editor-label">
            Có phải là tour?
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.IsTour)
            @Html.ValidationMessageFor(model => model.IsTour)
        </div>

        <p>
            <input type="submit" value="Create" />
        </p>
    </fieldset>
}

<div>
    @Html.ActionLink("Back to List", "Index")
</div>
